<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<script>

var ws = new WebSocket("ws://localhost:8081/echo");
 
ws.onopen = function(evt) {
	console.log("Connection open ...");
	ws.send("Hello WebSockets!");
};
/* 
ws.onmessage = function(evt) {
	console.log("Received Message: " + evt.data);
	ws.close();
};
*/
 
ws.onclose = function(evt) {
	console.log("Connection closed.");
};

</script>
</head>
<body>

</body>
</html>

